From 9bab027d65ef993c80799347044df715728808ca Mon Sep 17 00:00:00 2001 From: robertl Date: Mon, 28 Jul 2003 16:43:53 +0000 Subject: [PATCH] Better Garmin icon mappings for geocaches from Ian Mahuron. --- gpsbabel/garmin_tables.h | 3 +++ gpsbabel/internal_styles.c | 27 +++++++++++++++++++++++++-- gpsbabel/mapsource.c | 2 +- 3 files changed, 29 insertions(+), 3 deletions(-) diff --git a/gpsbabel/garmin_tables.h b/gpsbabel/garmin_tables.h index a90fe5e0d..c7d56c99d 100644 --- a/gpsbabel/garmin_tables.h +++ b/gpsbabel/garmin_tables.h @@ -174,5 +174,8 @@ static icon_mapping_t icon_table[] = { { 17, 17, "White Buoy" }, { 35, 36, "White Dot" }, { 88, 8219, "Zoo" }, + { 117, 8255, "Micro-Cache" }, /* icon for "Geocache" */ + { 48, 161, "Virtual cache" }, /* icon for "Scenic Area" */ + { 117, 8255, "Multi-Cache" }, /* icon for "Geocache" */ { -1, -1, NULL }, }; diff --git a/gpsbabel/internal_styles.c b/gpsbabel/internal_styles.c index ad0a04065..1751a6d21 100644 --- a/gpsbabel/internal_styles.c +++ b/gpsbabel/internal_styles.c @@ -1,6 +1,29 @@ -/* This file is machine-generated from the style/ directory */ +/* This file is machine-generated from the contents of style/ */ /* by mkstyle.sh. Editing it by hand is an exeedingly bad idea. */ +static char arc[] = +"# gpsbabel XCSV style file\n" +"#\n" +"# Format: GPSBabel arc filter format\n" +"# Author: Ron Parker\n" +"# Date: 17 July 2003\n" +"#\n" + +"DESCRIPTION GPSBabel arc filter file\n" +"EXTENSION txt\n" + +"#\n" +"# FILE LAYOUT DEFINITIIONS:\n" +"#\n" +"FIELD_DELIMITER TAB\n" +"RECORD_DELIMITER NEWLINE\n" + +"#\n" +"# INDIVIDUAL DATA FIELDS, IN ORDER OF APPEARANCE:\n" +"#\n" +"IFIELD LAT_DECIMAL, \"\", \"%08.5f\"\n" +"IFIELD LON_DECIMAL, \"\", \"%08.5f\"\n" +; static char csv[] = "# gpsbabel XCSV style file\n" "#\n" @@ -458,4 +481,4 @@ static char xmapwpt[] = "IFIELD DESCRIPTION, \"\", \"%-.78s\"\n" ; #include "defs.h" -style_vecs_t style_list[] = {{ "xmapwpt", xmapwpt } , { "xmap", xmap } , { "s_and_t", s_and_t } , { "ozi", ozi } , { "nima", nima } , { "mxf", mxf } , { "gpsman", gpsman } , { "gpsdrive", gpsdrive } , { "fugawi", fugawi } , { "dna", dna } , { "custom", custom } , { "csv", csv } , {0,0}}; +style_vecs_t style_list[] = {{ "xmapwpt", xmapwpt } , { "xmap", xmap } , { "s_and_t", s_and_t } , { "ozi", ozi } , { "nima", nima } , { "mxf", mxf } , { "gpsman", gpsman } , { "gpsdrive", gpsdrive } , { "fugawi", fugawi } , { "dna", dna } , { "custom", custom } , { "csv", csv } , { "arc", arc } , {0,0}}; diff --git a/gpsbabel/mapsource.c b/gpsbabel/mapsource.c index 26f2f1b7b..6b4a9b08f 100644 --- a/gpsbabel/mapsource.c +++ b/gpsbabel/mapsource.c @@ -257,7 +257,7 @@ mps_waypt_pr(const waypoint *wpt) icon = mps_find_icon_number_from_desc(wpt->icon_descr, MAPSOURCE); - if (get_cache_icon(wpt)) { + if (get_cache_icon(wpt) && (strcmp(wpt->icon_descr, "Geocache Found") != 0)) { icon = mps_find_icon_number_from_desc(get_cache_icon(wpt), MAPSOURCE); } -- 2.30.2